From 65f380fd217bc7c60766749e61c2eaebdd81de18 Mon Sep 17 00:00:00 2001
From: Angus_Wang <Angus_Wang@asus.com>
Date: Tue, 22 Aug 2017 14:35:22 +0800
Subject: [PATCH] Rename on-board sound card.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Change-Id: Ice0fa2f88e64a692ad0e10bd2ec5a93db1d13afd
Reviewed-on: https://tp-biosrd-v02/gerrit/80273
Reviewed-by: Jamess Huang(黃以民) <Jamess_Huang@asus.com>
Tested-by: Jamess Huang(黃以民) <Jamess_Huang@asus.com>
---
 sound/usb/card.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/sound/usb/card.c b/sound/usb/card.c
index a1cbaa5f7fc9..8e0a852a7bb5 100644
--- a/sound/usb/card.c
+++ b/sound/usb/card.c
@@ -407,6 +407,12 @@ static int snd_usb_audio_create(struct usb_interface *intf,
 	}
 	strim(card->shortname);
 
+	/* OnBoard ALC4040 Audio Codec */
+	if (USB_ID_VENDOR(chip->usb_id) == 0x0bda &&
+	    USB_ID_PRODUCT(chip->usb_id) == 0x481a) {
+		strlcat(card->shortname, " OnBoard", sizeof(card->shortname));
+	}
+
 	/* retrieve the vendor and device strings as longname */
 	if (quirk && quirk->vendor_name && *quirk->vendor_name) {
 		len = strlcpy(card->longname, quirk->vendor_name, sizeof(card->longname));
